<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>多类名的使用方法</title>
    <style>
        .box {
            width: 100px;
            height: 100px;
        }

        .gred {
            background-color: red;
        }

        .ggreen {
            background-color: green;
        }

        .font35 {
            font-size: 35px;
        }

        .red {
            color: red;
        }

        .green {
            color: green;
        }
    </style>
</head>

<body>
    <div class="font35 red">刘德华</div>
    <div class="font35 green">你好</div>
    <div class="font35 red">我好</div>
    <div class="box gred"></div>
    <div class="box ggreen"></div>
    <div class="box gred"></div>
</body>

</html>